#ifndef SUBLOGIC_H
#define SUBLOGIC_H

//#include "common.h"

#include "protocol.h"
#include "wrap.h"

#include <time.h>

#define CHAT_DATABASE "chat_record.txt"

char* printTime();
void printMsg(msgdata* msg);
void eraseStr_n(char* buf);
void login(bool isLogin);
void LoginWidget();
void saveChatRecord(char* sender,char* receiver,char* msgcontent);
void chatRecordTofile();
void PrintchatRecord(char* who);


#endif
